import { TResponse } from '@/typings'

type TLoginResult = {
  token: string;
}

export type TMenu = {
  icon?: string;
  menuId: string;
  menuName?: string;
  parentId?: string;
  type?: number;
  url?: string;
  routerName: string;
  children: TMenu[];
}

export type TUserInFoResult = {
  avatarImg: string;
  menuEntityList: TMenu[];
  realName: string;
  roleId: string;
  roleName: string;
  username: string;
  status: number;
  updateTime: string;
  userId: string;
  authorities: string[];
}

export type TResponseCode = {
  uuid: string;
  img: string;
}

export type TLoginCheck = {
  username: string;
  password: string;
  code: string;
  uuid: string;
}

export interface IBaseVo<T> {
  formFileList?: object;
  form: T;
}

export type TResponseUserInfo = TResponse<TUserInFoResult>

export type TResponseLogin = TResponse<TLoginResult>
